<!--
 * @ModuleName: 功能模块名称
 * @author: 上海灿实工程设备-陈世亮
 * @Date: 2022-02-05 16:50:47
 * @FilePath: \electron_vue\src\App.vue
-->
<template>
  <img alt="Vue logo" src="./assets/logo.png" />
  第222版本
  <button @click="autoUpdate">获取更新</button>
</template>

<script setup>
import { onMounted } from "vue";

onMounted(() => {
  setTimeout(() => {
    window.electron.onMessage((val) => {
      console.log(val, "=====");
    });
  }, 1000);
});

function autoUpdate() {
  window.electron.ipcRenderer.send("update");
}
</script>

<style>
#app {
  font-family: Avenir, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-align: center;
  color: #2c3e50;
  margin-top: 60px;
}
</style>
